package quotation.web.qes.controller;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import quotation.R.R;
import quotation.web.qes.ddd.form.QesCaculateForm;
import quotation.web.qes.service.QesService;
import quotation.web.quotationSys.ddd.form.AddQuotationSysForm;
import quotation.web.user.service.UserService;

import javax.validation.Valid;
import java.math.BigDecimal;

/**
 * @author lyx
 * @date 2025/2/19
 */
@RestController
@RequestMapping("/qes")
@Api(tags = "qes计算")
public class QesController {

    @Autowired
    private QesService QesService;


    @PostMapping("/caculate")
    @ApiModelProperty(value = "qes计算")
    public R caculate(@RequestBody QesCaculateForm form) {

        BigDecimal caculate = QesService.caculate(form);
        return R.success("计算成功", caculate);
    }

}
